package com.dragon.modules.yuegou.entity.merchant;

import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 等级规则-明细实体类<br>
 * 对应的表为：mer_merchant_level_rule_detail<br>
 * 
 * @author pbuilder generated
 * @date 2019-09-23 15:29:06
 * @company sgy
 * @version 2.0
 */
@TableName("mer_merchant_level_rule_detail")
@ApiModel(description = "等级规则-明细")
public class MerchantLevelRuleDetailEntity {

	protected String id;

    /** 等级ID */
	@ApiModelProperty("等级ID")
	protected String levelRuleId;

    /** 购买单价 */
	@ApiModelProperty("购买单价")
	protected BigDecimal unitPrice;

    /** 折扣价 */
	@ApiModelProperty("折扣价")
	protected BigDecimal discountPrice;

    /** 折扣有效期开始日期 */
	@ApiModelProperty("折扣有效期开始日期")
	protected LocalDateTime startTime;

    /** 折扣有效期结束日期 */
	@ApiModelProperty("折扣有效期结束日期")
	protected LocalDateTime endTime;

    /** 有效期限，单位：月 */
	@ApiModelProperty("有效期限，单位：月")
	protected Integer periodValidity;

	/**
	 * 构造一个空等级规则-明细实体对象
	 */
	public MerchantLevelRuleDetailEntity(){
		super();
	}

	/**
	 * 依据其它对象的信息构造一个等级规则-明细实体对象
	 * 
	 * @param other 其它对象
	 */
	public MerchantLevelRuleDetailEntity(MerchantLevelRuleDetailEntity other){
		super();
     	this.id = other.id;
     	this.levelRuleId = other.levelRuleId;
     	this.unitPrice = other.unitPrice;
     	this.discountPrice = other.discountPrice;
     	this.startTime = other.startTime;
     	this.endTime = other.endTime;
     	this.periodValidity = other.periodValidity;
	}


	/**
	 * 获取
	 * 
	 * @return id 
	 */
	public String getId() {
		return id;
	}
  	
	/**
	 * 设置
	 * 
	 * @param id 
	 */
	public void setId(String id) {
		this.id = id;
	}

	/**
	 * 获取等级ID
	 * 
	 * @return levelRuleId 等级ID
	 */
	public String getLevelRuleId() {
		return levelRuleId;
	}
  	
	/**
	 * 设置等级ID
	 * 
	 * @param levelRuleId 等级ID
	 */
	public void setLevelRuleId(String levelRuleId) {
		this.levelRuleId = levelRuleId;
	}

	/**
	 * 获取购买单价
	 * 
	 * @return unitPrice 购买单价
	 */
	public BigDecimal getUnitPrice() {
		return unitPrice;
	}
  	
	/**
	 * 设置购买单价
	 * 
	 * @param unitPrice 购买单价
	 */
	public void setUnitPrice(BigDecimal unitPrice) {
		this.unitPrice = unitPrice;
	}

	/**
	 * 获取折扣价
	 * 
	 * @return discountPrice 折扣价
	 */
	public BigDecimal getDiscountPrice() {
		return discountPrice;
	}
  	
	/**
	 * 设置折扣价
	 * 
	 * @param discountPrice 折扣价
	 */
	public void setDiscountPrice(BigDecimal discountPrice) {
		this.discountPrice = discountPrice;
	}

	/**
	 * 获取折扣有效期开始日期
	 * 
	 * @return startTime 折扣有效期开始日期
	 */
	public LocalDateTime getStartTime() {
		return startTime;
	}
  	
	/**
	 * 设置折扣有效期开始日期
	 * 
	 * @param startTime 折扣有效期开始日期
	 */
	public void setStartTime(LocalDateTime startTime) {
		this.startTime = startTime;
	}

	/**
	 * 获取折扣有效期结束日期
	 * 
	 * @return endTime 折扣有效期结束日期
	 */
	public LocalDateTime getEndTime() {
		return endTime;
	}
  	
	/**
	 * 设置折扣有效期结束日期
	 * 
	 * @param endTime 折扣有效期结束日期
	 */
	public void setEndTime(LocalDateTime endTime) {
		this.endTime = endTime;
	}

	/**
	 * 获取有效期限，单位：月
	 * 
	 * @return periodValidity 有效期限，单位：月
	 */
	public Integer getPeriodValidity() {
		return periodValidity;
	}
  	
	/**
	 * 设置有效期限，单位：月
	 * 
	 * @param periodValidity 有效期限，单位：月
	 */
	public void setPeriodValidity(Integer periodValidity) {
		this.periodValidity = periodValidity;
	}

    public String toString() {
		return new StringBuilder().append("MerchantLevelRuleDetailEntity{").
			append("id=").append(id).
			append(",levelRuleId=").append(levelRuleId).
			append(",unitPrice=").append(unitPrice).
			append(",discountPrice=").append(discountPrice).
			append(",startTime=").append(startTime).
			append(",endTime=").append(endTime).
			append(",periodValidity=").append(periodValidity).
			append('}').toString();
    }

	/**
	 * 复制对象
	 * 
	 * @return 复制后的新实体对象
	 */
	public MerchantLevelRuleDetailEntity copy() {
		return new MerchantLevelRuleDetailEntity(this);
	}

    /**  */
	public static final String COL_ID = "id";

    /** 等级ID */
	public static final String COL_LEVEL_RULE_ID = "level_rule_id";

    /** 购买单价 */
	public static final String COL_UNIT_PRICE = "unit_price";

    /** 折扣价 */
	public static final String COL_DISCOUNT_PRICE = "discount_price";

    /** 折扣有效期开始日期 */
	public static final String COL_START_TIME = "start_time";

    /** 折扣有效期结束日期 */
	public static final String COL_END_TIME = "end_time";

    /** 有效期限，单位：月 */
	public static final String COL_PERIOD_VALIDITY = "period_validity";
}
